#ifndef _GT20L16S1Y_LIB_H_
#define _GT20L16S1Y_LIB_H_

#define ASCII_5X7 1
#define ASCII_7X8 2
#define ASCII_8X16_A 3
#define ASCII_8X16_F 4
#define ASCII_16X16_A 5
#define ASCII_16X16_T 6

extern unsigned char r_dat_bat(unsigned long address, unsigned short byte_long, unsigned char *p_arr); // SPI读取多个字节的函数
extern unsigned char r_dat(unsigned long address);                                                     // SPI读取一个字节的函数

// 返回0则是获取不到数据，返回1则表示输入ASCII在有效范围内
unsigned char S1Y_ASCII_GetData(unsigned char ASCIICode, unsigned long BaseAdd, unsigned char *DZ_Data);

void S1Y_gt_16_GetData(unsigned char MSB, unsigned char LSB, unsigned char *DZ_Data);
void S1Y_GB_EXT_816(unsigned int FontCode, unsigned char *DZ_Data);
unsigned int S1Y_UnicodeToGB2312(unsigned int UN_CODE);
void S1Y_get_cr_zf_Ar_1116(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_T_1116(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_1224(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_1632(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_Ar_1824(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_T_1824(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_Ar_2232(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_T_2232(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_2448(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_3264(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_Ar_3448(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_T_3448(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_cr_zf_Ar_4064(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_time_zf_2024(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_time_zf_2432(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_time_zf_3448(unsigned char Sequence, unsigned char *p_arr);

void S1Y_get_time_zf_4864(unsigned char Sequence, unsigned char *p_arr);

#endif
